import {BootstrapVue} from 'bootstrap-vue'

export async function msgAffirm(obj, msg, type) {
    let flag = false;
    await obj.$bvModal.msgBoxConfirm(msg, {
        title: '请确认信息',
        centered: true,
        okVariant: type,
        okTitle: '确定',
        cancelTitle: '取消',
    }).then(value => {
        flag = value
    }).catch(err => {
        console.log(err)
    })
    return flag;
}


export async function msgTip(obj, title,msg, type) {
    obj.$bvToast.toast(msg, {
        title: title,
        autoHideDelay: 2000,
        variant: type,
        solid: true}
        )
}



